package model.area_effect;

import model.map.GameMap;
import model.map.MapPoint;

/**
 * Singleton class that removes AoEs from the GameMap.
 * Should be instantiated early on.  First time instantiating
 * you must set the game map to the current game map;
 * @author Zachary
 */
public class AreaEffectRemover {
	private static AreaEffectRemover instance = null;
	private GameMap map;
	
	/**
	 * Get an instance of the AreaAffectRemover.
	 * @return
	 */
	public static AreaEffectRemover getInstance(){
		return instance;
	}
	
	/**
	 * Private constructor.
	 */
	public AreaEffectRemover(GameMap map){
		this.map = map;
		instance = this;
	}
	
	/**
	 * Remove the map area effect at the specified position from the game map.
	 * @param aoe
	 * @param point
	 */
	public void removeMapAreaEffectFromMap(MapAreaOfEffect aoe, MapPoint point){
		this.map.removeMapAreaOfEffect(aoe,point);
	}
	
	/**
	 * Remove the trap at the specified position from the game map.
	 * @param trap
	 * @param point
	 */
	public void removeTrapFromMap(Trap trap, MapPoint point){
		this.map.removeTrap(trap,point);
	}
	
	/**
	 * Remove the skill object at the specified position from the game map.
	 * @param object
	 * @param point
	 */
	public void removeSkillObjectFromMap(SkillObject object, MapPoint point){
		this.map.removeSkillObject(object,point);
	}
}
